package com.project.bean;

import java.time.LocalDate;

public class LinkBean {
    private int id;
    private LocalDate startDate = LocalDate.now();
    private String endDate = "未完成";
    private EmployeeBean employee;
    private ProjectBean project;

    public LinkBean() {
    }

    public LinkBean(int employeeId, int projectId) {
        EmployeeBean employee = new EmployeeBean();
        employee.setId(employeeId);
        this.employee = employee;
        ProjectBean project = new ProjectBean();
        project.setId(projectId);
        this.project = project;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public LocalDate getStartDate() {
        return startDate;
    }

    public void setStartDate(LocalDate startDate) {
        this.startDate = startDate;
    }

    public String getEndDate() {
        return endDate;
    }

    public void setEndDate(String endDate) {
        this.endDate = endDate;
    }

    public EmployeeBean getEmployee() {
        return employee;
    }

    public void setEmployee(EmployeeBean employee) {
        this.employee = employee;
    }

    public ProjectBean getProject() {
        return project;
    }

    public void setProject(ProjectBean project) {
        this.project = project;
    }

    @Override
    public String toString() {
        return "LinkBean{" +
                "id=" + id +
                ", startDate=" + startDate +
                ", endDate='" + endDate + '\'' +
                ", employee=" + employee +
                ", project=" + project +
                '}' + "\n";
    }
}
